<template>
  <div class="app-container">
    <iframe style="width: 100%;height: 85vh;border: none" src="https://www.jianyigongxiang.com/?s=/Member/index"></iframe>
  </div>
</template>

<script>
// import fetchList from '@/api/article'
import Pagination from '@/components/Pagination'
import { getXuan } from '@/utils/limits.js'
import { mapGetters } from 'vuex' // Secondary package based on el-pagination

export default {
  name: 'ArticleList',
  components: {
    Pagination
  },
  filters: {
    statusFilter(status) {
      const statusMap = {
        published: 'success',
        draft: 'info',
        deleted: 'danger'
      }
      return statusMap[status]
    }
  },
  data() {
    return {
      list: null,
      total: 0,
      listLoading: true,
      listQuery: {
        page: 1,
        limit: 20
      },
      status: {},
      role: {},
      roleIndex: '',
      statusIndex: 0
    }
  },
  computed: {
    ...mapGetters([
      'permission_routes',
      'roles'
    ])
  },
  created() {
    var xuanList = [{
      name: '等级设置',
      url: '/shareholder/level',
      pd: true
    }]
    var xuanList1 = getXuan(xuanList, this.roles)
    this.$store.dispatch('user/changeXuan', {
      key: 'xuanList',
      value: xuanList1
    })
    this.$store.dispatch('user/changeXuan', {
      key: 'xuan',
      value: 0
    })

    this.getList()
  },
  methods: {
    getList() {
      this.listLoading = true
      var list = {
        'errno': 0,
        'error': 'ok',
        'data': [
          {
            'id': '3',
            'name': '普通会员[默认等级]',
            'shenqing': '无',
            'money': '0.00',
            'shengji': '默认等级无需升级',
            'bili': '无分销权限',
          }, {
            'id': '4',
            'name': '钻石会员',
            'shenqing': '无',
            'money': '0.00',
            'shengji': '不自动升级',
            'bili': '10.00% / 3.00%',
          }, {
            'id': '5',
            'name': '微股东',
            'shenqing': '订单金额满3000.00元',
            'money': '0.00',
            'shengji': '不自动升级',
            'bili': '15.00% / 8.00%',
          }],
        'total': 0


      }

      this.total = list.data.total
      this.list = list.data
      this.status = list.data.status
      this.listLoading = false
    },
    handleSelectionChange(val) {
      console.log(val.length)
      this.xuancount = val.length
      this.multipleSelection = val
    }
  }
}
</script>

<style scoped>
.edit-input {
  padding-right: 100px;
}

.cancel-btn {
  position: absolute;
  right: 15px;
  top: 10px;
}

.typelists {
  cursor: pointer;
  margin-right: 30px;
  margin-bottom: 10px;
  vertical-align: middle;
  font-size: 12px;
}

.typexuan {
  color: #41c3a8;
}

::v-deep .el-table--enable-row-hover .el-table__body tr:hover > td {
  background-color: #616b74;
  color: #fff;
}

::v-deep .el-table--enable-row-hover .el-table__body tr > td {
  color: #000;
}

/* ::v-deep .el-table__body .el-table__row.hover-row td {
  background-color: #616b74
} */
</style>
